<?php 
class ControllerCommonHeaderin extends Controller {
	public function index() {
		$data['title'] = $this->document->getTitle();
		$token = $this->session->data['token'];
		$data['viewreminder'] = $this->url->link('memory/viewreminder', '', true)."&token=".$token;
		$data['knowledgeexam'] = $this->url->link('memory/knowledgeexam', '', true)."&token=".$token;
		$data['knowledgelist'] = $this->url->link('memory/knowledgelist', '', true)."&token=".$token;
		$data['createknowledge'] = $this->url->link('memory/createknowledge', '', true)."&token=".$token;
		$data['systemsetting'] = $this->url->link('memory/systemsetting', '', true)."&token=".$token;
		$data['privatesetting'] = $this->url->link('memory/privatesetting', '', true)."&token=".$token;
		$data['message'] = $this->url->link('memory/message', '', true)."&token=".$token;
		$data['donation'] = $this->url->link('memory/donation', '', true)."&token=".$token;
		$this->load->model("user/user");
		$nickname = $this->model_user_user->getNicknameByUserid($this->session->data['user_id']);
		$data['username'] = !empty($nickname) ? $nickname : $this->session->data['username'];
		$data['logout'] = $this->url->link('common/logout', '', true)."&token=".$token;

		$data['description'] = $this->document->getDescription();
		$data['keywords'] = $this->document->getKeywords();
		$data['links'] = $this->document->getLinks();
		$data['styles'] = $this->document->getStyles();
		return $this->load->view('common/headerin',$data);
	}
}